A virtual extensible local area network (VxLAN) uses a Media Access Control (MAC) Over user datagram protocol (UDP) technology, which is an overlay network technology or a tunnel technology. The VxLAN encapsulates a data packet sent by a virtual machine into the UDP and uses the Internet Protocol (IP)/MAC of a physical network as an outer-header to perform encapsulation. The data packet then is transmitted over a physical IP network and is decapsulated by a tunnel termination point after reaching a destination, and data is sent to a target virtual machine. A packet sent using the VxLAN technology is a VxLAN packet, and the VxLAN packet usually includes a VxLAN tunnel header and an original payload. The VxLAN tunnel header includes an outer destination MAC address, an outer source MAC address, an outer destination IP address, an outer source IP address, an outer UDP header, and a VxLAN network identifier (VNI). The original payload includes an inner destination MAC address, an inner source MAC address, inner 802.1Q, and an original Ethernet valid payload. Implementation of sending of a VxLAN packet requires information about the VxLAN tunnel header and the original payload.
On a computer device running a virtual machine service, a network adapter can identify and forward a virtual local area network (VLAN) packet sent by the virtual machine. However, for the VxLAN packet, the network adapter does not have a capability of obtaining information required for forwarding the VxLAN packet, and therefore the network adapter cannot encapsulate and send the VxLAN packet.